/*
 Navicat Premium Data Transfer

 Source Server         : local
 Source Server Type    : MySQL
 Source Server Version : 50612
 Source Host           : localhost
 Source Database       : demo

 Target Server Type    : MySQL
 Target Server Version : 50612
 File Encoding         : utf-8

 Date: 07/18/2013 23:18:53 PM
*/

SET NAMES utf8;
SET FOREIGN_KEY_CHECKS = 0;

-- ----------------------------
--  Table structure for `ls_attachments`
-- ----------------------------
DROP TABLE IF EXISTS `ls_attachments`;
CREATE TABLE `ls_attachments` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `content_type` varchar(255) NOT NULL,
  `created_date` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
  `enabled` bit(1) DEFAULT NULL,
  `existed` bit(1) DEFAULT NULL,
  `file_name` varchar(255) DEFAULT NULL,
  `file_size` int(11) DEFAULT NULL,
  `file_url` varchar(255) DEFAULT NULL,
  `user_id` int(11) NOT NULL,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='附件表';

-- ----------------------------
--  Table structure for `ls_users`
-- ----------------------------
DROP TABLE IF EXISTS `ls_users`;
CREATE TABLE `ls_users` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `login_name` varchar(64) NOT NULL COMMENT '登录名称',
  `name` varchar(64) DEFAULT NULL COMMENT '用户名',
  `password` varchar(255) DEFAULT NULL,
  `salt` varchar(64) DEFAULT NULL,
  `enabled` bit(1) DEFAULT NULL,
  `roles` varchar(255) DEFAULT NULL,
  `email` varchar(64) DEFAULT NULL COMMENT '邮箱',
  `phone` varchar(64) DEFAULT NULL COMMENT '手机号',
  `avatar_url` varchar(45) DEFAULT NULL,
  `regist_date` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
  `last_login_date` timestamp NULL DEFAULT NULL,
  PRIMARY KEY (`id`),
  UNIQUE KEY `idx_nickname` (`login_name`),
  UNIQUE KEY `idx_email` (`email`) USING BTREE,
  UNIQUE KEY `idx_phone` (`phone`)
) ENGINE=InnoDB AUTO_INCREMENT=11 DEFAULT CHARSET=utf8 COMMENT='用户表';

-- ----------------------------
--  Records of `ls_users`
-- ----------------------------
BEGIN;
INSERT INTO `ls_users` VALUES ('10', 'test1@qq.com', 'test1', '4e88c2114d8693470fcf5e08356a4578c9b0626f', 'e3d578d7cc9f84f0', b'1', 'user,player', null, null, '/static/images/default-avatar.png', '2013-02-23 17:47:15', '2013-02-23 17:47:01');
COMMIT;

SET FOREIGN_KEY_CHECKS = 1;
